import { defineConfig, presetUno } from 'unocss'
import presetAttributify from '@unocss/preset-attributify'
import transformerVariantGroup from '@unocss/transformer-variant-group'
import transformerDirectives from '@unocss/transformer-directives'
import presetRemToPx from '@unocss/preset-rem-to-px'
export default defineConfig({
  presets: [
    presetAttributify({}),
    /** 默认预设 */
    presetUno(),
    presetRemToPx({
      baseFontSize: 4
    })
  ],
  transformers: [transformerVariantGroup(), transformerDirectives()],
  theme: {
    colors: {
      body: 'var(--xy-body-color)',
      primary: 'var(--xy-primary-color)',
      'primary-light': 'var(--xy-primary-light-color)',
      'normal-text': 'var(--xy-normal-text-color)',
      medium: 'var(--xy-medium-text-color)',
      grey: 'var(--xy-grey-text-color)',
      light: 'var(--xy-light-color)',
      hover: 'var(--xy-hover-color)',
      warning: 'var(--xy-warning-color)',
      success: 'var(--xy-success-color)',
      danger: 'var(--xy-danger-color)',
      white: 'var(--xy-white-color)',
      normal: 'var(--xy-normal-color)',
      disabled: 'var(--xy-disabled-color)',
      'hover-bg': 'var(--xy-hover-bg-color)',
      'hover-text': 'var(--xy-hover-text-color)',
      'warning-light': 'var(--xy-warning-light-color)'
    }
  }
})
